<!--
 * @Descripttion: 
 * @version: 
 * @Author: sueRimn
 * @Date: 2022-10-12 15:52:41
 * @LastEditors: sueRimn
 * @LastEditTime: 2023-02-22 15:16:29
-->


<template>
  <div class="approval_form">
    <el-row v-for="(row, index) in structure" :key="index + '_row'">
      <el-col
        :span="col.span"
        :class="col.className"
        v-for="(col, ind) in row.cols"
        :key="ind + '_col'"
      >
        <span v-for="(ele, eind) in col.elements" :key="eind + '_ele'">
          <template v-if="ele.type == 'string' && ele.className == 'title'">
            <p :class="ele.className">{{ ele.descip }}</p>
          </template>
          <template v-if="ele.type == 'input'">
            <el-input
              v-model="modelObj[ele.name]"
              :class="ele.className"
              :placeholder="ele.placeholder"
            ></el-input>
          </template>
          <div
            v-else-if="ele.type == 'string' && ele.className != 'title'"
            v-html="ele.descrip"
          ></div>
        </span>
      </el-col>
    </el-row>
  </div>
</template>
<script>
export default {
  name: "approvalForm",
  data() {
    return {};
  },
  created() {},
  methods: {},
};
</script>